package com.itlong.cloud.iottp;

import com.itlong.cloud.POJO.VO.SDKMessageV3;
import com.itlong.cloud.POJO.VO.sdk.v3.hw.CancelTravelWrap;
import com.itlong.cloud.POJO.VO.sdk.v3.hw.DoorCtrlCloseWrap;
import com.itlong.cloud.POJO.VO.sdk.v3.hw.DoorCtrlOpenWrap;
import com.itlong.cloud.POJO.VO.sdk.v3.hw.SetTravelWrap;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * <desc>
 * SDKV3暴露接口
 * </desc>
 *
 * @createDate 2021-05-17
 */
@FeignClient(name = "iot-tp-service")
public interface ISDKV3Client {

    /**
     * <desc>
     * 预约乘梯
     * </desc>
     *
     * @param setTravelWrap 乘梯指令
     * @return
     * @author zhouchun
     * @createDate 2021-05-17
     */
    @RequestMapping(path = "/sdkv3/cloudElevatorCall", method = RequestMethod.POST)
    SDKMessageV3 cloudElevatorCall(@RequestBody SetTravelWrap setTravelWrap);

    /**
     * <desc>
     * 开门
     * </desc>
     *
     * @param doorCtrlOpenWrap 开门指令
     * @return
     * @author zhouchun
     * @createDate 2021-05-17
     */
    @RequestMapping(path = "/sdkv3/openDoor", method = RequestMethod.POST)
    SDKMessageV3 openDoor(@RequestBody DoorCtrlOpenWrap doorCtrlOpenWrap);

    /**
     * <desc>
     * 关门
     * </desc>
     *
     * @param doorCtrlCloseWrap 关门指令
     * @return
     * @author zhouchun
     * @createDate 2021-05-17
     */
    @RequestMapping(path = "/sdkv3/closeDoor", method = RequestMethod.POST)
    SDKMessageV3 closeDoor(@RequestBody DoorCtrlCloseWrap doorCtrlCloseWrap);

    /**
     * <desc>
     * 取消乘梯
     * </desc>
     *
     * @param cancelTravelWrap 取消乘梯指令
     * @return
     * @author zhouchun
     * @createDate 2021-06-16
     */
    @RequestMapping(path = "/sdkv3/submitCancelElevator", method = RequestMethod.POST)
    SDKMessageV3 submitCancelElevator(@RequestBody CancelTravelWrap cancelTravelWrap);

}